var t = getApp();

Page({
    data: {
        language: "",
        froze: 0,
        coin_name: "",
        usable: 0,
        transfer_status: !1,
        titlew: "",
        content: "",
        show: !1
    },
    onLoad: function(t) {
        this.getBalance(), this.getInfo();
    },
    onReady: function() {
        var t = wx.getStorageSync("langIndex");
        this.setData({
            language: t.en
        });
    },
    onShow: function() {
        this.getBalance();
    },
    onHide: function() {},
    onUnload: function() {},
    onPullDownRefresh: function() {},
    onReachBottom: function() {},
    onShareAppMessage: function() {},
    getBalance: function() {
        var e = this, n = t.getNetAddresss("plugin.coin.Frontend.Controllers.page.index");
        t._getNetWork({
            url: n,
            success: function(t) {
                var n = t.data;
                1 === n.result ? e.setData({
                    froze: n.data.froze,
                    coin_name: n.data.coin_name,
                    title: n.data.love_name,
                    usable: n.data.usable,
                    transfer_status: n.data.transfer_status
                }) : wx.showToast({
                    title: n.msg,
                    icon: "none",
                    duration: 2e3
                });
            },
            fail: function(t) {
                console.log(t);
            }
        });
    },
    getInfo: function() {
        var e = this, n = t.getNetAddresss("plugin.coin.Frontend.Controllers.explain.index");
        t._getNetWork({
            url: n,
            success: function(t) {
                var n = t.data;
                1 === n.result ? e.setData({
                    content: n.data.content,
                    titlew: n.data.title
                }) : wx.showToast({
                    title: n.msg,
                    icon: "none",
                    duration: 2e3
                });
            },
            fail: function(t) {
                console.log(t);
            }
        });
    },
    gotoPage: function(t) {
        console.log(t);
        var e = t.target.dataset.url || t.currentTarget.dataset.url;
        "overseas_explain" != e ? wx.navigateTo({
            url: "/packageB/member/" + e + "/" + e
        }) : this.setData({
            show: !0
        });
    },
    onClickLeft: function() {
        this.setData({
            show: !1
        });
    },
    onClickRight: function() {
        wx.navigateTo({
            url: "/packageB/member/overseas_list/overseas_list"
        });
    }
});